const baseSize = 10
function setRem () {
  // 当前页面宽度相对于 750 宽的缩放比例
  const scale = document.documentElement.clientWidth / 1920
  console.log(scale)
  document.documentElement.style.fontSize = (baseSize * Math.min(scale, 1)) + 'px'
}
// 初始化
setRem()
window.onresize = function () {
  setRem()
}